import Model from '@/utils/http.js'
const api = new Model()
//勋章墙
export function medalWallList() {
	return api.get({
		url: '/shenye/medal/wall/list'
	})
}
// 获取 我的产值
export function getMyWalletInfo() {
	return api.get({
		url: '/mine/center/getMyWalletInfo'
	})
}
// 勋章列表 - 钱包首页
export function medalWallMedalList() {
	return api.get({
		url: '/shenye/medal/wallet/medal/list'
	})
}
// 查询数字宝箱列表
export function paradiseCustomerPlatformList(params) {
	return api.get({
		url: '/shenye/paradise/customer/platform/list',
		data: params
	})
}

// 查询用户奖池列表
export function paradiseCustomerJackpotList(params) {
	return api.get({
		url: '/shenye/paradise/customer/jackpot/list',
		data: params
	})
}
// 查询用户数字宝箱详情 ( 订单详情 )
export function paradiseCustomerPlatformDetail(params) {
	return api.get({
		url: '/shenye/paradise/customer/platform/detail',
		data: params
	})
}
// 
export function customerCouponRefund(id) {
	return api.put({
		url: `/shenye/customer/coupon/refund/${id}`,
	})
}
export function paradiseActivateCustomerBox(id) {
	return api.post({
		url: `/shenye/paradise/activate/customer/box/${id}`,
	})
}

export function customerCouponRefundHint(id) {
	return api.get({
		url: `/shenye/customer/coupon/refund/hint/${id}`,
	})
}

// 查询待领取nfr数量
export function paradiseWaitDrawNfr(id) {
	return api.get({
		url: '/shenye/paradise/wait/draw/nfr',
	})
}
// 勋章行业加成说明
export function medalDescriptionMedalId(medalId) {
	return api.get({
		url: `/shenye/medal/description/${medalId}`,
	})
}

// 勋章详情（数字权益卡介绍图片）
export function medalEquityCardImageMedalId(medalId) {
	return api.get({
		url: `/shenye/medal/equity/card/image/${medalId}`,
	})
}

// 勋章晋级卡编号
export function medalCardnoMedalId(medalId) {
	return api.get({
		url: `/shenye/medal/cardno/${medalId}`,
	})
}
// 勋章晋级
export function medalPromotionCustomerMedalId(customerMedalId) {
	return api.post({
		url: `/shenye/medal/promotion/${customerMedalId}`,
	})
}

// 勋章激活
export function medalActivateMedalId(medalId) {
	return api.post({
		url: `/shenye/medal/activate/${medalId}`,
	})
}

// 勋章升级行业列表
export function medalUpgradeIndustryList(params) {
	return api.get({
		url: '/shenye/medal/upgrade/industry/list'
	})
}
// 勋章升级-转赠页面
export function medalUpgradePageIndustryId(industryId) {
	return api.get({
		url: `/shenye/medal/upgrade/page/${industryId}`,
	})
}
//2023-5-23
//使用数字宝箱（椰椰邮差）
export function useCustomerBox(data) {
	return api.post({
		url: `/shenye/paradise/use/customer/box`,
		data
	})
}
//2023-6-7
//查询糖果nfr权益
export function candieHistoryLs(data) {
	return api.get({
		url: `/equityManager/equityCard/candie/history/list`,
		data
	})
}
//激活数字权益卡
export function merchantCardActivate(id) {
	return api.put({
		url: `/equityManager/equityCard/customer/merchant/card/activate/${id}`,
	})
}
// 查询商家权益二维码
export function merchantEquityCode(data){
	return api.get({
		url:'/common/v1/merchant/equity/code',
		data:data
	})
}
// 查询商家数字权益卡权益信息
export function merchantCardEquity(id){
	return api.get({
		url: `/equityManager/equityCard/customer/merchant/card/equity/${id}`,
	})
}

// 查询用户数字宝箱列表V2 新
export function paradiseCustomerPlatformListV2(data){
	return api.get({
		url: '/shenye/paradise/customer/platform/listV2',
		data
	})
}

// 钱包 - 用户权益卡区块链证书
export function equityCardCustomerBlockDetail(id){
	return api.get({
		url: `/equityManager/equityCard/customer/block/detail/${id}`,
	})
}

// 钱包 -勋章区块链证书
export function medalBlockDetail(medalId){
	return api.get({
		// url: `/shenye/medal/block/detail/${medalId}`,
		url: `/equityManager/equityCard/block/detail/v2/${medalId}`,
	})
}

// 新钱包首页
export function mineCenterCustomerWallet(){
	return api.get({
		url: '/mine/center/customer/wallet',
	})
}

// 最近获得NFR列表
export function customerRecentlyNfrList(){
	return api.get({
		url: '/mine/center/customer/recently/nfr/list',
	})
}

// 钱包信息
export function wealthInfo(){
	return api.get({
		url: '/mine/center/wealthInfo',
	})
}
// 当前可用权益
export function getCurrentEquityCard(){
	return api.get({
		url: '/equityManager/equityCard/getCurrentEquityCard',
	})
}
// 已获得勋章
export function getCustomerEquityMedalCardList(){
	return api.get({
		url: '/mine/center/getCustomerEquityMedalCardList',
	})
}
// 查询积分转赠配置信息
export function getDonationConfig(){
	return api.get({
		url: '/platform/wallet/v1/getDonationConfig',
	})
}
// h5积分转赠
export function platformWallet(data) {
	return api.post({
		// url: `/platform/wallet/v1`,
		url: `/donation/order/integral`,
		type:1,
		data
	})
}
// h5手动取消转赠
export function walletCancel(id) {
	return api.post({
		url: `/platform/wallet/v1/cancel/${id}`,
	})
}
// 扫用户资产码
export function qrcodeInfo(data) {
	return api.get({
		url: `/personal/center/scan/asset/qrcode/info`,
		data
	})
}
//用户持有 数字权益卡转赠配置列表
export function getEquityCardDonationList(data) {
	return api.get({
		url: `/equity/card/donation/getEquityCardDonationList`,
		data
	})
}
//用户权益卡转赠配置列表
export function getCustomerEquityCardDonationList(data) {
	return api.get({
		url: `/equity/card/donation/getCustomerEquityCardDonationList`,
		data
	})
}
// H5积分转赠明细列表
export function walletV1RecordList(data) {
	return api.get({
		url:'/platform/wallet/v1/record/list',
		data
	})
}
// 查询分红详情
export function bonusPoolDetail(data) {
	return api.get({
		url:'/shenye/bonus/pool/detail',
		data
	})
}
// 查询分红记录
export function bonusPoolRecord(data) {
	return api.get({
		url:'/shenye/bonus/pool/record',
		data
	})
}
// 领取分红
export function bonusPoolBonusReceive(data) {
	return api.post({
		url:'/shenye/bonus/pool/bonus/receive',
		data
	})
}
// <------------神椰 2.3.1 Star----------------->
// 查询用户可用打卡活动列表
export function equityManagerActivityList(){
	return api.get({
		url: '/equityManager/equityCard/equity/activity/list',
	})
}
// 打卡-可使用权益列表 、资产列表-可使用权益列表
export function equityManagerEquityCardV2(data){
	return api.get({
		url: '/equityManager/equityCard/current/equity/card/v2',
		data
	})
}
// 打卡-可使用权益数量
export function equityManagerEquityCardCount(){
	return api.get({
		url: '/equityManager/equityCard/equity/card/count'
	})
}

//查询权益码(快速打卡)
export function shenyeEquityQrcode(data){
	return api.get({
		url: '/shenye/paradise/equity/qrcode',
		data
	})
}
// 用户分红信息
export function mineCocoBonusInfo(){
	return api.get({
		url: '/mine/center/coco/bonus/info',
	})
}
// 用户分红信息
export function mineCocoBonusHistory(data){
	return api.get({
		url: '/mine/center/coco/bonus/history',
		data
	})
}
// 资产列表-可使用权益数量
//  <----------------end--------------------->